import { createPinia } from 'pinia'
import { createApp } from 'vue'
import piniaPluginPersistedstate from 'pinia-plugin-persistedstate'
import App from './App.vue'
import router from './router'
// 懒加载指令全局指令注册
import { lazyLodingPlugin } from '@/directives'

//全局组件插件
import { componentPlugin } from '@/components'

//引入默认样式
import '@/styles/common.scss'

const app = createApp(App)

//注册持久化
const pinia=createPinia()
pinia.use(piniaPluginPersistedstate)

app.use(pinia)
app.use(router)
//懒加载指令注册
app.use(lazyLodingPlugin)
//全局组件注册
app.use(componentPlugin)
app.mount('#app')
